//Source file: D:\\test\\com\\ce\\pms\\house\\model\\HouseGrp.java

package com.ce.pms.house.model;

import javax.persistence.Column;
import javax.persistence.Entity;
import javax.persistence.GeneratedValue;
import javax.persistence.Id;
import javax.persistence.JoinColumn;
import javax.persistence.ManyToOne;
import javax.persistence.Table;

import com.sitechasia.webx.core.model.IDomainObject;

/**
 * 实体名称：楼栋单元 关联表：HM_HOUSE_GRP
 *
 * @author Adama Yue
 *
 */
@Entity
@Table(name = "HM_HOUSE_GRP")
public class HouseGrp implements IDomainObject{

	/**
	 * 单元主键
	 */
	@Id
	@GeneratedValue
	@Column(name = "HOUSE_GRP_ID")
	private Long keyword;

	/**
	 * 单元名称
	 */
	@Column(name = "HOUSE_GRP_NAME", nullable = false, insertable = true, updatable = true, length = 80)
	private String name;

	/**
	 * 楼栋
	 */
	@ManyToOne
	@JoinColumn(name = "BUILDING_ID", nullable = false)
	private BuildingDomain building;

	/**
	 * @roseuid 484F3FA5001F
	 */
	public HouseGrp() {

	}

	/**
	 * @param id
	 * @roseuid 48464852009C
	 */
	public HouseGrp(Long id) {
	}

	/**
	 * mini constructor
	 * @param name 单元名
	 * @param building 楼栋
	 */
	public HouseGrp(String name, BuildingDomain building) {
		super();
		this.name = name;
		this.building = building;
	}
	/**************************************************
	 * Accessors and Modifiers
	 **************************************************/
	public BuildingDomain getBuilding() {
		return building;
	}

	public void setBuilding(BuildingDomain building) {
		this.building = building;
	}

	public Long getKeyword() {
		return keyword;
	}

	public void setKeyword(Long keyword) {
		this.keyword = keyword;
	}

	public String getName() {
		return name;
	}

	public void setName(String name) {
		this.name = name;
	}



}
